home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Gamer (Italian) 30
/
PC Gamer IT CD 30 1-2.iso
/
MOTS
/
GAMEDATA
/
EPISODE
/
JKM_PCG.GOO
/
cog_s1l2_elev_switch2.cog
< prev
next >
Wrap
Text File
|
1998-02-25
|
3KB
|
111 lines
# Jedi Knight Missions Cog Script
#
# S1L2_elev_switch2.cog
#
# [DS/RD/IS/JS/TL]
#
# (C) 1997 LucasArts Entertainment Co. All Rights Reserved
# =========================================================
symbols
message activate
message timer
message pulse
surface button0 linkid=1
surface button1 nolink
surface light0 linkid=4
surface light1 linkid=4
surface light2 linkid=4
surface light3 linkid=4
thing elevator linkid=2
thing trooper linkid=3
flex start_wait=0.25 desc=pause_before_moving_up
flex sleeptime=2.0
flex speed=4.0
int done0=0 local
#cog storm0
#cog storm1
#cog storm2
sound wav0=Activate02.wav
sound troopervoice=ST50149.wav
sound kyle
sound kyle2
sound alarm=00alarmloop03.wav
sound transound
sound tranactive
int soundnum local
end
# =========================================================
code
activate:
if ((GetSenderId() == 2) && (GetCurFrame(elevator) != 0))
{
SetTimer(sleeptime);
PlaySoundThing(tranactive, elevator, 1, -1, -1, 0);
}
if (GetSenderId() == 1)
{
if (done0 == 1) return;
else if (done0 == 0)
{
done0=1;
// SendMessage(storm0, entered);
// SendMessage(storm1, entered);
// SendMessage(storm2, entered);
SetWallCel(button0, 1);
PlaySoundPos(wav0, SurfaceCenter(button0), 0.6, -1, -1, 0);
PlaySoundLocal(alarm, 4, 0, 0);
MoveToFrame(elevator, 2, speed);
// PlaySoundThing(transound, elevator, 2, -1, -1, 1);
sleep(2.5);
PlaySoundLocal(kyle, 3, 0, 256);
SetPulse(0.25);
sleep(3.5);
PlaySoundPos(troopervoice,SurfaceCenter(button1), 4, -1, -1, 256);
sleep(4.5);
PlaySoundLocal(kyle2, 3, 0, 256);
}
}
return;
# .........................................................
timer:
MoveToFrame(elevator, 0, 8);
soundnum=PlaySoundThing(transound, elevator, 1, -1, -1, 1);
return;
#..........................................................
pulse:
SetWallCel(light0, 1);
SetWallCel(light1, 1);
SetWallCel(light2, 1);
SetWallCel(light3, 1);
return;
arrived:
if (GetCurFrame(elevator) != 0) return;
if (GetCurFrame(elevator) == 0)
{
StopSound(soundnum, 0);
}
return;
end